package com.yixin.hospital.entity.domain;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import lombok.Data;

import java.io.Serializable;
import java.util.Date;

/**
 * 药品仓库权限表
 * @TableName drug_depository_auth
 */
@TableName(value ="drug_depository_user_auth")
@Data
public class DrugDepositoryUserAuth implements Serializable {

    /**
     * 药品仓库权限表id
     */
    @TableId(type = IdType.AUTO)
    private Long id;

    /**
     * 员工id
     */
    private Long userId;

    /**
     * 库id
     */
    private Long drugDepositoryId;

    /**
     * 操作权限类型
     */
    private Integer optType;

    /**
     * 创建人
     */
    private String createdBy;

    /**
     * 创建时间
     */
    private Date createdTime;

    /**
     * 更新人
     */
    private String updatedBy;

    /**
     * 更新时间
     */
    private Date updatedTime;

    @TableField(exist = false)
    private static final long serialVersionUID = 1L;

    public DrugDepositoryUserAuth() {}

    public DrugDepositoryUserAuth(Long userId, Long drugDepositoryId, Integer optType, String createdBy, String updatedBy) {
        this.userId = userId;
        this.drugDepositoryId = drugDepositoryId;
        this.optType = optType;
        this.createdBy = createdBy;
        this.updatedBy = updatedBy;
    }
}